package com.dyna.demo.device.convert;

import com.dyna.core.convert.BeanConverter;
import com.dyna.demo.device.domain.entity.DcDevicesInfo;
import com.dyna.demo.device.domain.resp.DcDeviceInfoResp;

public class DcDeviceInfoConvert {

    public static final BeanConverter<DcDevicesInfo, DcDeviceInfoResp> DEVICE_CONVERTER = source -> {
        DcDeviceInfoResp target = new DcDeviceInfoResp();
        target.setName(source.getName());
        target.setCode(source.getCode());
        target.setLongitude(source.getLongitude());
        target.setLatitude(source.getLatitude());
        return target;
    };

}
